package scuff.msg.util

/**
 * Will infer the class from the id and the provided package.
 */
trait IdAsClassName[PL <: AnyRef] extends Classifier[String, PL] {
  
  protected def basePackage: java.lang.Package
  
  private def fullName(id: String) = basePackage.getName+"."+id
  
  def classify(id: String) = Class.forName(fullName(id)).asInstanceOf[Class[PL]]
}